package com.ljb.nfcreadandwritedemo.read;

import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.View;
import android.widget.TextView;

import com.ljb.nfcreadandwritedemo.BaseNFCActivity;
import com.ljb.nfcreadandwritedemo.R;

/**
 * Created by ljb on 2018/8/3.
 */
public class ReadMUActivity extends BaseNFCActivity {

    private TextView tvRead;

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_read);
        tvRead = findViewById(R.id.rv_read);

    }

    @Override
    protected void onNewIntent(Intent intent) {
        super.onNewIntent(intent);
        String ret = nfcHelper.readNFC_MU(intent);
        if (ret != null) {
            nfcHelper.vibrate(this);
            tvRead.setText("内容为: " + ret);
        }
    }
}
